	<script type="text/javascript">
	function updatesettingslist(){
		//alert("douchebag");
		$("#settingslist").html('<p>Please wait while the Settings are updated...</p>')
		$.get("settingUpdate", function(data){
			//var nodelist_content_string = data;
			
			var JSONobj = eval(data);
			var settinglist_content_string = "";
			//alert("douchebag");
			jQuery.each(JSONobj, function(i, val) {
				
			settinglist_content_string += '<div id="'+val.name+'_setting" class="submitLineContainer">'+
											'<div class="submitTextLeft"><label for="input'+val.name+'">'+val.short_desc+'</label></div>'+
											'<div class="submitTextCenter"><input class="stdInputField numeric" id="input'+val.name+'" name="'+val.name+'" type="text" value="'+val.value+'"/></div>'+
											'<div class="submitTextRight"><label for="input'+val.name+'">'+val.long_desc+'</label></div>'+
										'</div>';
			});
			//alert(settinglist_content_string);
			$("#settingslist").html(settinglist_content_string);
			$("input.numeric").numeric();
		});
	}                                         
	$(document).ready(function() {
		//alert();
		updatesettingslist();
		$("#submit_insertSettings").click(function(){
			//$("#settingslist").html('<p>Please wait while the Settings are updated...</p>')
			var hasError = false;

			//jQuery.each($("settings_input"), function(i, val) {
			//	if(val.val() == '') {
			//		alert(val.name+" is empty");
			//		hasError = true;
			//	}
			//}); 
			var showtasksVal = $("#inputshowtasks").val();
			var shownodesVal = $("#inputshownodes").val();
			var showresultsVal = $("#inputshowresults").val();
			$.post("insertSettings",
					   { showtasks: showtasksVal, shownodes: shownodesVal, showresults: showresultsVal},
					   	function(data){
						   updatesettingslist();
						}
					);	

			return false;
		});
	});

	</script>
	<form method="post" action="insertSettings" id="sendsettings">
	
		<div id="settingslist"></div>
		<button type="submit" id="submit_insertSettings">Save</button>	
			
	</form>
				
